package com.leyu.mall.service.user;

import java.util.List;

import com.leyu.mall.domain.user.Permision;
import com.leyu.mall.domain.user.Role;
import com.leyu.mall.domain.user.UserBase;

/**
 * @author change
 * 
 */
public interface UserService {
	public boolean registerUser(UserBase user);

	public UserBase findByLoginName(String loginName);

	public boolean changePassword(String loginName, String oldPassword,
			String newPassword);

	public List<Role> getUserRoles(Long userId);
	
	public List<Permision> getPermisionsByRole(Long roleId);
	
	public List<Permision> getPermisionsByUser(Long userId);
}
